<template>
  <div>
    <el-form-item label="主要负责人">
      <el-input v-model="value.majorName" :disabled="disabled" class="input" placeholder="请输入主要负责人" @change="handleChange" />
    </el-form-item>
    <el-form-item label="安全负责人">
      <el-input v-model="value.safeName" :disabled="disabled" class="input" placeholder="请输入安全负责人" @change="handleChange" />
    </el-form-item>
    <el-form-item label="安全管理机构">
      <el-input v-model="value.safetyManagementOrg" :disabled="disabled" class="input" placeholder="请输入安全管理机构" @change="handleChange" />
    </el-form-item>
    <el-form-item label="职工人数">
      <el-input-number v-model="value.staffNum" :disabled="disabled" @change="handleChange" />
    </el-form-item>
    <el-form-item label="安全生产标准化">
      <el-select v-model="value.safetyStandard" :disabled="disabled" placeholder="请选择" class="input" @change="handleChange">
        <el-option
          v-for="dict in dict.type.sec_product_standard"
          :key="dict.value"
          :label="dict.label"
          :value="dict.value"
        />
      </el-select>
    </el-form-item>
    <el-form-item label="重点行业领域">
      <el-select v-model="value.vipIndustryArea" :disabled="disabled" placeholder="请选择" class="input" @change="handleChange">
        <el-option
          v-for="dict in dict.type.sec_product_standard"
          :key="dict.value"
          :label="dict.label"
          :value="dict.value"
        />
      </el-select>
    </el-form-item>
  </div>
</template>
<script>
export default {
  name: 'Basic',
  dicts: ['sec_product_standard', 'sec_major_domain'],
  props: {
    disabled: Boolean,
    value: {
      type: Object,
      default: () => ({})
    }
  },
  methods: {
    handleChange() {
      this.$emit('input', this.value)
      this.$emit('change', this.value)
    }
  }
}
</script>
